package com.ruoyi.central.domain;

import com.baomidou.mybatisplus.annotation.*;
import com.ruoyi.common.validation.group.InsertGroup;
import com.ruoyi.common.validation.group.UpdateGroup;
import lombok.Data;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.annotation.Length;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 操作工位对象 top_central_operation_station
 *
 * @author ruoyi
 * @date 2022-03-02
 */
@Data
@TableName("top_central_operation_station")
public class TopCentralOperationStation extends BaseEntity{

private static final long serialVersionUID = 1L;

    /** 编号 */
    @TableId
    @Length(min = 0,max = 10,message="编号 数据长度不能大于 10")
    private Integer id;

    /** 操作工位名称 */
    @Excel(name = "操作工位名称")
    @NotBlank(groups = {InsertGroup.class,UpdateGroup.class},message = "操作工位名称不能为空")
    @Length(min = 0,max = 50,message="操作工位名称 数据长度不能大于 50")
    private String name;

    /** 区域 */
    @Excel(name = "区域")
    @NotNull(groups = {InsertGroup.class,UpdateGroup.class},message = "区域不能为空")
    @Length(min = 0,max = 10,message="区域 数据长度不能大于 10")
    private Integer areaId;

    /** 区域对象 */
    @TableField(exist = false)
    private TopCentralArea area;

    /** 加工状态 */
    @Excel(name = "加工状态")
    @NotNull(groups = {InsertGroup.class,UpdateGroup.class},message = "加工状态不能为空")
    @Length(min = 0,max = 1,message="加工状态 数据长度不能大于 1")
    private Integer processingStatus;

    @Excel(name = "分组名称")
    @Length(min = 0,max = 2,message="分组名称 数据长度不能大于 2")
    @TableField(updateStrategy = FieldStrategy.IGNORED)
    private Integer groupId;

    /** 操作工位与物料关系对象 **/
    @TableField(exist = false)
    private TopCentralOperationStationMaterial operationStationMaterial;
}
